package com.modebing.activiti.demo1;

import org.activiti.engine.delegate.DelegateTask;
import org.activiti.engine.delegate.TaskListener;

public class MyTaskListener implements TaskListener {
    @Override
    public void notify(DelegateTask delegateTask) {
        if ("创建请假单".equals(delegateTask.getName())&&"create".equals(delegateTask.getEventName())){
            delegateTask.setAssignee("zhangsan-Listener");
        }
    }
}
